<?php
namespace App\Model;

/**
 * @Author:: HuangYin
 * @DateTime: 2017-01-16 11:23
 *
 * @Description:
 */
class MemberRecharge extends BaseModel
{
    // 充值
    const RECHARGE = 1;
    // 消费
    const SPENDING = 2;
    // 退款
    const REFUND = 3;

    protected $table = 'member_recharge';

    protected $visible = ['id', 'uid', 'name', 'store_id', 'type', 'money', 'memo', 'created_at'];

    public function recharge()
    {
        return $this->hasOne('App\Model\Member', 'uid', 'uid');
    }
}